<template name="components">
	<view>
		<scroll-view scroll-y class="page">
			<image src="/static/home-banner.jpg" mode="widthFix" class="response"></image>
			<view class="nav-list">
				<navigator hover-class='none' :url="'/pages/' + item.dir + '/' + item.name" class="nav-li" navigateTo :class="'bg-'+item.color"
				 :style="[{animation: 'show ' + ((index+1)*0.2+1) + 's 1'}]" v-for="(item,index) in elements" :key="index">
					<view class="nav-title">{{item.title}}</view>
					<view class="nav-name">{{item.name}}</view>
					<text :class="'cuIcon-' + item.cuIcon"></text>
				</navigator>
			</view>
			<view class="cu-tabbar-height"></view>
		</scroll-view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				elements: [{
						title: '办理会员',
						dir:'member',
						name: 'newmember',
						color: 'purple',
						cuIcon: 'vipcard'
					},
					{
						title: '办理套餐',
						dir:'member',
						name: 'nav',
						color: 'mauve',
						cuIcon: 'formfill'
					},
					{
						title: '充值',
						dir:'member',
						name: 'list',
						color: 'pink',
						cuIcon: 'list'
					},
					{
						title: '查看会员',
						dir:'member',
						name: 'card',
						color: 'brown',
						cuIcon: 'newsfill'
					}
				],
			};
		}
	}
</script>

<style>
	.page {
		height: 100vh;
	}
</style>
